import 'package:json_annotation/json_annotation.dart';

part 'test_post_request.g.dart';

@JsonSerializable(explicitToJson: true, anyMap: true)
class TestPostRequest {
  final String title;
  final String body;
  final int userId;

  TestPostRequest(this.title, this.body, this.userId);

  factory TestPostRequest.fromJson(Map<String, dynamic> json) =>
      _$TestPostRequestFromJson(json);

  Map<String, dynamic> toJson() => _$TestPostRequestToJson(this);
}
